# Contributor: lonjil <alpine@lonjil.xyz>
# Maintainer: lonjil <alpine@lonjil.xyz>
pkgname=qalculate-gtk
# the pkgver must be kept in sync with: libqalculate
pkgver=4.2.0
pkgrel=0
pkgdesc="Multi-purpose desktop calculator - GTK+ version"
url="https://qalculate.github.io/"
license="GPL-2.0-or-later"
arch="all"
makedepends="
	autoconf
	automake
	glib-dev
	gtk+3.0-dev
	intltool
	libqalculate-dev=~${pkgver%.*}
	libtool
	"
subpackages="$pkgname-doc $pkgname-lang"
source="https://github.com/Qalculate/qalculate-gtk/releases/download/v$pkgver/qalculate-gtk-$pkgver.tar.gz"
options="!check" # no test suite

prepare() {
	default_prepare

	autoreconf -f
}

build() {
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--mandir=/usr/share/man
	make
}

package() {
	make DESTDIR="$pkgdir" install
}

sha512sums="
ca0c864174f862a2f78e8743c3d7556da53d1d890773c5c8907d1d210f2101419cd083cfd9351e98c4b5fc64c602d5bc53fccecc8df1aa0451ee8418fbdfaa32  qalculate-gtk-4.2.0.tar.gz
"
